Skip to content

refactor(support-math): Decouple support math from node APIs#1158

Merged
leumor merged 1 commit intodevelopfrom
feature/support-math-decoupling
Mar 23, 2026
Merged

refactor(support-math): Decouple support math from node APIs#1158
leumor merged 1 commit intodevelopfrom
feature/support-math-decoupling

Conversation

@leumor
Copy link
Collaborator

@leumor leumor commented Mar 23, 2026

Summary

  • add KeyspaceMath and TimeSkewAlertCallback as support-side keyspace and time-skew contracts
  • update DecayingKeyspaceAverage and TimeDecayingRunningAverage to use those support-side contracts instead of node.* APIs
  • keep node compatibility by delegating through Location and TimeSkewDetectorCallback, and add direct helper/parity coverage plus Javadoc for the new types

How to test

  • ./gradlew compileJava
  • ./gradlew test --tests "network.crypta.support.math.*"
  • ./gradlew test --tests "network.crypta.node.LocationTest"
  • ./gradlew test
  • javac -proc:none -Xdoclint:all -Werror -d /tmp/doclint-out-keyspace src/main/java/network/crypta/support/math/KeyspaceMath.java
  • javac -proc:none -Xdoclint:all -Werror -d /tmp/doclint-out-timeskew src/main/java/network/crypta/support/math/TimeSkewAlertCallback.java

Add support-side keyspace and time-skew contracts so support.math no longer depends on node APIs.

Also delegate the node-side compatibility types to the new support helpers and expand the supporting tests and Javadoc around the extracted behavior.
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: dd5cf692fd

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@sonarqubecloud
Copy link

@leumor leumor merged commit 50d34ef into develop Mar 23, 2026
7 of 8 checks passed
@leumor leumor deleted the feature/support-math-decoupling branch March 23, 2026 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant